<?php 
namespace app\admin\validate;
use think\Validate;
class Club extends Validate{
	// 正则表达式 regex = ['zip'=>'\d{6}',...]
  protected $regex = [
  ];

  // 当前验证的规则
  protected $rule = [
    'title'=>'require',
  	'type'=>'require',
  	'tel'=>'require|length:11|number',
  	'y'=>'require|number',
    'm'=>'require|number',
    'd'=>'require|number',
    'addr'=>'require',

  ];

  // 验证提示信息
  protected $message = [
    'title.require'=>'标题必填',
    'type.require'=>'类型必选',
  	'tel.require'=>'联系方式必填',
  	'y.require'=>'年份必填',
  	'm.require'=>'月份必填',
  	'd.require'=>'日期必填',
    'y.number'=>'年份维数组',
    'm.number'=>'月份是数字',
    'd.number'=>'日期是数字',
  	'addr.require'=>'地点必填',
  ];

  // 验证场景 scene = ['edit'=>'name1,name2,...']
  protected $scene = [
  	// 'add'=>'uname,email,pwd',
  	// 'edit'=>'uname,email',
  ];
}

